import React, { Component } from "react";
import { topSongs } from "../../api/songs";
import { formatDuration } from "../../utils/format";
import bus from "../../utils/bus";
export default class Songs extends Component {
  constructor(props) {
    super();
    this.state = {
      // 选中的类别的索引
      selectIndex: 0,
      // 类别数组
      types: [
        { type: 0, name: '全部' },
        { type: 7, name: '华语' },
        { type: 96, name: '欧美' },
        { type: 8, name: '日本' },
        { type: 16, name: '韩国' },
      ],
      tableData: [],
    };
  }
  componentDidMount() {
    this.loadSong();
  }
  async loadSong() {
    const res = await topSongs({
      type:
    });
    if (code === 200) {
      console.log(res);
    }
  }
  render() {
    return <div>歌曲页面</div>;
  }
}
